package cn.anecansaitin.jep.parser.ast.node.expression;

import cn.anecansaitin.jep.parser.ast.node.Node;
import cn.anecansaitin.jep.parser.ast.node.expression.literal.Literal;
import cn.anecansaitin.jep.types.TypeInfo;

public sealed abstract class Expression extends Node permits Array, Binary, FunctionCall, Grouping, Identifier, Member, Super, Ternary, This, Unary, Literal {
    private final TypeInfo resultType;

    public Expression(TypeInfo resultType, int line, int column) {
        super(line, column);
        this.resultType = resultType;
    }

    public TypeInfo resultType() {
        return resultType;
    }
}
